package cn.hackcloud.designpattern.observer;

public class Baidu implements Observer{
	private float temperature;
	private float pressure;
	private float humidity;

	@Override
	public void update(float temperature, float pressure, float humidity) {
		this.temperature = temperature;
		this.pressure = pressure;
		this.humidity = humidity;
		display();
	}

	public void display() {
		System.out.println("今天天气情况 温度: " + temperature + " 气压:" + pressure + " 湿度:" + humidity);
	}
}
